<template lang="">
    <div class="pagination">
        <!-- current-page:当前页码 -->
        <el-pagination
      :current-page="currentPage"
      :page-size="pageSize"
      @current-change="getPagination"
      layout="total, prev, pager, next, jumper"
      :total="total">
    </el-pagination>
    </div>
</template>
<script>
export default {
    props: {
        pageSize: {
            type: Number,
            default: 10
        },
        total: {
            type: Number,
            default: 100
        }
    },
    data() {
        return {
            currentPage: 1,
        }
    },
    methods: {
        getPagination(current) {
            this.$emit('getPagination', current);
        }
    }
}
</script>
<style lang="less" scoped>
    .pagination {
        padding: 10px;
        background: #fff;
        text-align: right;
    }
</style>